<template>
  <div>
    <footer>
      <div class="arrow" @click="syy"></div>
      <span>职位详情</span>
    </footer>
    <div class="top_name">
      <span class="top_name_top"> {{ zwxq.name }} </span>
      <span class="top_name_bottom">
        <span class="iconfont icon-dingwei"></span>
        不限
        <span>|</span>
        不限
        <span>|</span>
        不限
        <span>|</span>
        男女不限
        <span class="top_name_bottom_right"> {{ zwxq.money }} </span>
      </span>
    </div>

    <div class="box">
      <router-link :to="'/Gsxq'" style="text-decoration: none">
        <div class="box_left">
          <span class="iconfont icon-dalou"></span>
        </div>
        <div class="box_right_kh">></div>
        <div class="box_right">
          <p class="box_right_top">{{ zwxq.gsname }}</p>
          <span class="box_right_bottom"> 综合指数98 </span>
          <span> {{ zwxq.hy }} </span>
        </div>
      </router-link>
    </div>

    <div class="border">
      <span class="border_left">联系方式</span>
      <div class="border_right">
        <span>复制</span>
      </div>
    </div>
    <div class="center">
      <ul>
        <h4>工作时间</h4>
        <li>{{ zwxq.gzsj }}</li>
        <h4>工作地点</h4>
        <li>{{ zwxq.gzdd }}</li>
        <h4>工作内容</h4>
        <li v-for="(item, key) in zwxq.gznr" :key="key">
          {{ item }}
        </li>
      </ul>
    </div>
    <div class="red">
      <div class="red_left">
        <span class="iconfont icon-yk_gantanhao"></span>
      </div>
      <div class="red_right">
        <span
          >未标明收费的职位不会收取任何费用。若商家要求缴纳费闻或押金。清提高哲棉并第一时间向我们奉报!
        </span>
      </div>
    </div>
    <div class="wntj">
      <span>为你推荐</span>
      <div class="wntj_bl"></div>
    </div>
    <div class="wntj_box">
      <ul>
        <li v-for="(item, key) in wntj" :key="key">
          <router-link
            :to="'/Zwxq/' + key"
            @click.native="sx"
            style="text-decoration: none"
          >
            <span class="sx_Zwxq">{{ item.name }}</span>
            <span class="wntj_box_right">{{ item.money }}</span>
            <p>
              <span class="iconfont icon-dingwei"></span>
              <span
                >不限
                <span>|</span>
                不限
                <span>|</span>
                不限
                <span>|</span>
                男女不限</span
              >
              <span class="wntj_box_right"> {{ item.moneydw }}</span>
            </p>
          </router-link>
        </li>
      </ul>
    </div>
    <div class="dian"></div>
    <div class="bottom">
      <div class="bottom_left">
        <span class="iconfont icon-liaotian"></span>
        <span>咨询</span>
      </div>
      <div class="bottom_center">
        <span class="iconfont icon-shoucang"></span>
        <span>收藏</span>
      </div>
      <div class="bottom_right">
        <span>立即报名</span>
      </div>
    </div>
  </div>
</template>
<script>
import axios from "axios";
export default {
  data() {
    return {
      zwxq: "",
      wntj: "",
    };
  },
  name: "Home",
  compnents: {},
  created() {
    console.log(this.$route.params.id);
    axios({
      url: " http://localhost:3000/zwxq?id=" + this.$route.params.id,
      method: "get",
      params: { zwxq: this.zwxq },
    }).then((res) => {
      // console.log(res.data);
      this.zwxq = res.data[0];
      res.data;
    });
    axios({
      url: " http://localhost:3000/wntj",
      method: "get",
      params: { wntj: this.wntj },
    }).then((res) => {
      // console.log(res.data);
      this.wntj = res.data;
      res.data;
    });
  },
  methods: {
    sx() {
      history.go(0);
    },
    syy() {
      history.go(-1);
    },
  },
};
</script>
<style scoped>
@import url("../../assets/font/font_cxl/iconfont.css");

.arrow {
  margin-left: 0.2rem;
  width: 0.14rem;
  height: 0.14rem;
  border-top: 0.03rem solid black;
  border-right: 0.03rem solid black;
  transform: rotate(225deg);
  position: absolute;
  top: 0.3rem;
  /* color: #63adfa; */
}
.sx_Zwxq {
  color: #000;
}
footer span {
  position: absolute;
  top: 0.2rem;
  left: 38%;
  font-size: 0.24rem;
}
.icon-liaotian,
.icon-shoucang {
  font-size: 0.22rem;
}
.bottom {
  z-index: 999;
  background-color: white;
  font-size: 0.22rem;
  width: 100%;
  height: 0.72rem;
  position: fixed;
  bottom: 0rem;
  border-top: 0.04rem solid #f7f9f8;
}
.bottom_left {
  float: left;
  margin-left: 0.2rem;
  line-height: 0.72rem;
  color: #a2a4a3;
}
.bottom_center {
  float: left;
  margin-left: 0.26rem;
  line-height: 0.72rem;
  color: #a2a4a3;
}
.bottom_right {
  font-size: 0.16rem;
  float: left;
  margin-top: 0.15rem;
  margin-left: 0.33rem;
  width: 1.5rem;
  height: 0.42rem;
  background-color: #62b0fb;
  border-radius: 0.3rem;
  color: white;
  text-align: center;
  line-height: 0.42rem;
}
.top_name {
  margin-left: 0.17rem;
  margin-top: 0.7rem;
}
.top_name_top {
  font-size: 0.2rem;
}
.top_name_top {
  display: block;
}
.top_name_bottom {
  display: block;
  margin-top: 0.06rem;
  font-size: 0.14rem;
  color: #a0a0a0;
}
.top_name_bottom_right {
  float: right;
  margin-right: 0.3rem;
  color: red;
}
.box {
  width: 3.47rem;
  height: 0.96rem;
  margin-top: 0.25rem;
  margin-left: 0.17rem;
  border-radius: 0.3rem;
  background: linear-gradient(to right, #99c7fb, #d5c1fc);
}
.box_left {
  width: 0.55rem;
  height: 0.5rem;
  border-radius: 50%;
  text-align: center;
  float: left;
  line-height: 0.5rem;
  background-color: #61e9d4;
  margin-left: 0.32rem;
  margin-top: 0.21rem;
}
.icon-dalou {
  font-size: 0.3rem;
  color: white;
}
.box_right {
  color: white;
  font-size: 0.14rem;
  /* margin-top: 0.3rem; */
}
.box_right p {
  /* margin-top: 0.3rem; */
  color: white;
  margin-left: 0.3rem;
  font-size: 0.14rem;
  /* line-height: 0.3rem; */
  padding-top: 0.2rem;
}
.box_right span {
  font-size: 0.12rem;
}
.box_right_kh {
  float: right;
  margin-right: 0.2rem;
  font-size: 0.24rem;
  color: white;
  margin-top: 0.1rem;
}
.border {
  margin-top: 0.3rem;
  margin-left: 0.17rem;
  width: 3.4rem;
  height: 0.3rem;
  background-color: #fbfbfb;
  font-size: 0.14rem;
  color: #d7d7d7;
}
.border_left {
  margin-left: 0.52rem;
}
.border_right {
  display: inline-block;
  margin-left: 1.16rem;
  width: 0.62rem;
  height: 0.22rem;
  color: white;
  background-color: #66cafe;
  border-radius: 0.3rem;
  text-align: center;
  line-height: 0.22rem;
}
.center {
  margin: 0;
}
.center ul {
  margin: 0;
  font-size: 0.12rem;
  padding: 0;
  margin-left: 0.17rem;
}
.center ul li {
  list-style: none;
  width: 3.4rem;
  margin-bottom: 0.42rem;
}
.dian {
  margin-bottom: 1.2rem;
}
.red {
  width: 100%;
  height: 0.47rem;
  background-color: #fcf1eb;
}
.red_left {
  float: left;
  margin-top: 0.1rem;
}
.icon-yk_gantanhao {
  font-size: 0.3rem;
  margin-left: 0.13rem;
  color: red;
}
.red_right {
  width: 3rem;
  float: left;
  font-size: 0.12rem;
  margin-top: 0.07rem;
  margin-left: 0.1rem;
  color: #e96e45;
}
.wntj {
  font-size: 0.18rem;
  margin-top: 0.2rem;
  margin-left: 0.17rem;
  position: relative;
}
.wntj_bl {
  width: 0.7rem;
  height: 0.13rem;
  position: absolute;
  bottom: 0;
  z-index: -1;
  background: linear-gradient(to right, #70d1fb, transparent);
}
.wntj_box ul {
  padding: 0;
  margin-left: 0.17rem;
}
.wntj_box ul p {
  font-size: 0.1rem;
  color: #848484;
}
.wntj_box ul li {
  list-style: none;
  margin-top: 0.15rem;
}
.wntj_box_right {
  float: right;
  color: #ac542f;
  margin-right: 0.5rem;
}
</style>
